package cz.cvut.manatee.client.login;

import com.google.gwt.event.shared.GwtEvent;

public class LoginEvent extends GwtEvent<LoginHandler> {
	public static final Type<LoginHandler> TYPE = new Type<LoginHandler>();
	
	protected String login;
	protected String name;
	
	@Override
	protected void dispatch(LoginHandler handler) {
		handler.onLogin(this);
	}
	
	@Override
	public com.google.gwt.event.shared.GwtEvent.Type<LoginHandler> getAssociatedType() {
		return TYPE;
	}
	
	public LoginEvent(String login, String name) {
		this.login = login;
		this.name  = name;
	}
	
	public String getLogin() {
		return this.login;
	}
	
	public String getName() {
		return this.name;
	}
}
